package com.myworkbench.workbench.domain.entity.resource;

public final  class ResourceNamedSQL {

    public  final  static  String findAllResourceByUserId="SELECT \n" +
            "  _res.*\n" +
            "FROM\n" +
            "  resource _res \n" +
            "WHERE " +
            "_res.is_delete= :isDelete and _res.id IN \n" +
            "  (\n" +
            "  \n" +
            "  SELECT \n" +
            "    rrl.resource_id \n" +
            "  FROM\n" +
            "    rel_role_resource rrl,\n" +
            "    rel_user_role  rur \n" +
            "  WHERE rrl.role_id = rur.role_id" +
            " AND rur.user_id=:userId" +
            " " +
            ")";

}
